package com.zhang.teachingcommunity_spring.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.zhang.teachingcommunity_spring.controller.resultType.Pagination;
import com.zhang.teachingcommunity_spring.mapper.entity.Post;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;
import java.util.Map;

@Mapper
public interface PostMapper extends BaseMapper<Post> {
    List<Map<String, Object>> getDifferentSubjectInCountFn();
    List<Map<String,Object>> getPostList(Integer subjectId, Pagination pagination, Integer sortNumber);
    List<Map<String,Object>> getPostListCount(Integer subjectId,  Integer sortNumber);
    List<Map<String,Object>> getHotSort();
    List<Map<String,Object>> getPostInfo();
}
